package cn.powertime.evaluation.service.impl;

import cn.powertime.evaluation.entity.CpsSearchHistory;
import cn.powertime.evaluation.mapper.CpsSearchHistoryMapper;
import cn.powertime.evaluation.service.CpsSearchHistoryService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class CpsSearchHistoryServiceImpl extends ServiceImpl<CpsSearchHistoryMapper,CpsSearchHistory> implements CpsSearchHistoryService{

    @Autowired
    private  CpsSearchHistoryMapper searchHistoryMapper;

    @Override
    public boolean ownSave(CpsSearchHistory menu) {
        return save(menu);
    }

    @Override
    public boolean ownUpdateById(CpsSearchHistory menu) {
        return updateById(menu);
    }

    @Override
    public boolean batch(Long userId) {
        int i =searchHistoryMapper.batch(userId);
        return i>0;
    }

}
